package enterprise.manage.dao;

import org.hibernate.Query;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.security.userdetails.User;
import org.springframework.stereotype.Repository;
import org.springframework.transaction.annotation.Transactional;
import org.springside.modules.orm.hibernate.HibernateDao;


import java.util.List;

/**
 * Created by IntelliJ IDEA.
 * User: liyong
 * Date: 2010-8-30
 * Time: 14:24:37
 * desc
 */
@Repository
@Transactional
public class LoginDao extends HibernateDao<User, Long> {

    /**
     * 验证用户登录方法
     * @param username    用户名
     * @param password    密码
     * @return 验证用户名密码 是否正确
     */
    @Autowired
    private UserDao userDao;
     public boolean login(String userName, String password) {
         userDao.findBy("userName",userName);

 
         return false;
     }
}